﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;

namespace MMessaging.MessagingEx.Common
{
	public static class DebuggingHelper
	{
		public static int _currentObservedThreadID = 0;

		public static string MarkCurrentThreadAsObserved()
		{
			_currentObservedThreadID = Thread.CurrentThread.ManagedThreadId;
			return "set observated thread id:" + _currentObservedThreadID;
		}

		public static bool IsObservedThread
		{
			get
			{
				return Thread.CurrentThread.ManagedThreadId == _currentObservedThreadID;
			}
		}
	}
}
